package Chapter06.Homework;

import java.util.Scanner;

public class Test05 {
    public static void main(String[] args) {
        Adminstrator adminstrator=new Adminstrator();
        adminstrator.name="小方";
        adminstrator.password="123456";
        Scanner input=new Scanner(System.in);
        System.out.println("请输入用户名：");
        String names=input.next();
        System.out.println("请输入密码：");
        int pwd=input.nextInt();
        if(adminstrator.name.equals(names)){
            System.out.println("请输入新的密码：");
            pwd=input.nextInt();
            System.out.println("新的密码"+pwd);
        }else {
            System.out.println("无权限");
        }
    }
}
